<?php
/* 
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/**
 * Description of home_references_m
 *
 * @author Gidaff_01
 */
class Home_references_m extends CI_Model{
    //put your code here
    function __construct() {
        parent::__construct();
        $this->load->database();
    }

    function get_all_references($per_page,$off_set){
        return $this->db->select()
        ->from('our_references')
        ->limit($per_page,$off_set)
        ->get()
        ->result_array();
    }

    function get_references_by_id($id){
        $this->db->select();
        $this->db->from('our_references');
        $this->db->where('id',$id);
        $query=$this->db->get();
        return $query;
    }
}
?>
